home *** CD-ROM | disk | FTP | other *** search
/ Programming Languages Suite / ProgramD2.iso / Visual Database / Visual BASIC 5.0 (Ent. Edition) / Vb5ent Extractor.EXE / VB / SAMPLES / PGUIDE / PROGWOB / PWOMAIN.FRM (.txt) < prev    next >
Encoding:
Visual Basic Form  |  1996-11-26  |  2.9 KB  |  94 lines

  1. VERSION 5.00
  2. Begin VB.Form frmProgWObMain 
  3.    Caption         =   "Programming with Objects"
  4.    ClientHeight    =   3195
  5.    ClientLeft      =   60
  6.    ClientTop       =   345
  7.    ClientWidth     =   4680
  8.    LinkTopic       =   "Form2"
  9.    ScaleHeight     =   3195
  10.    ScaleWidth      =   4680
  11.    StartUpPosition =   3  'Windows Default
  12.    Begin VB.CommandButton cmdImplements 
  13.       Caption         =   "Polymorphism and the &Implements keyword"
  14.       Height          =   375
  15.       Left            =   240
  16.       TabIndex        =   3
  17.       Top             =   1680
  18.       Width           =   4095
  19.    End
  20.    Begin VB.CommandButton cmdEvents 
  21.       Caption         =   "Raising and Handling &Events"
  22.       Height          =   375
  23.       Left            =   240
  24.       TabIndex        =   2
  25.       Top             =   1200
  26.       Width           =   4095
  27.    End
  28.    Begin VB.CommandButton cmdFriends 
  29.       Caption         =   "Passing UDTs between objects with &Friend Functions"
  30.       Height          =   375
  31.       Left            =   240
  32.       TabIndex        =   0
  33.       Top             =   240
  34.       Width           =   4095
  35.    End
  36.    Begin VB.CommandButton cmdCYOCC 
  37.       Caption         =   "&Creating Your Own Collection Classes"
  38.       Height          =   375
  39.       Left            =   240
  40.       TabIndex        =   1
  41.       Top             =   720
  42.       Width           =   4095
  43.    End
  44. Attribute VB_Name = "frmProgWObMain"
  45. Attribute VB_GlobalNameSpace = False
  46. Attribute VB_Creatable = False
  47. Attribute VB_PredeclaredId = True
  48. Attribute VB_Exposed = False
  49. Option Explicit
  50. ' frmProgWObMain shows other forms using
  51. '   the hidden global variables Visual
  52. '   Basic creates for each form class
  53. '   (frmFriends, frmCYOCC, ______, and _____,
  54. '   in this case).  The hidden global
  55. '   variable is described in "Life Cycle
  56. '   of Visual Basic Forms" in Books Online.
  57. ' The forms are shown modeless, and
  58. '   frmProgWObMain specifies itself (Me)
  59. '   as the owner of each form.  As a
  60. '   result, the owned forms always appear
  61. '   on top of frmProgWObMain.
  62. Private Sub cmdEvents_Click()
  63.     frmEvents.Show vbModeless, Me
  64. End Sub
  65. ' Friend Members Passing UDTs
  66. Private Sub cmdFriends_Click()
  67.     frmFriends.Show vbModeless, Me
  68. End Sub
  69. ' Creating Your Own Collection Classes
  70. Private Sub cmdCYOCC_Click()
  71.     frmCYOCC.Show vbModeless, Me
  72. End Sub
  73. Private Sub cmdImplements_Click()
  74.     frmImplements.Show vbModeless, Me
  75. End Sub
  76. Private Sub Form_Unload(Cancel As Integer)
  77.     If frmFriends Is Nothing Then
  78.         Unload frmFriends
  79.         Set frmFriends = Nothing
  80.     End If
  81.     If frmCYOCC Is Nothing Then
  82.         Unload frmCYOCC
  83.         Set frmCYOCC = Nothing
  84.     End If
  85.     If frmEvents Is Nothing Then
  86.         Unload frmEvents
  87.         Set frmEvents = Nothing
  88.     End If
  89.     If frmImplements Is Nothing Then
  90.         Unload frmImplements
  91.         Set frmImplements = Nothing
  92.     End If
  93. End Sub
  94.